package com.xxxx;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.loadbalancer.LoadBalanced;
import org.springframework.context.annotation.Bean;
import org.springframework.web.client.RestTemplate;

import java.util.Random;

/**
 * @author zzuli_huahua
 * @version 1.0
 * @date 2022/1/13 17:09
 */
@SpringBootApplication
public class ServiceConsumerApplication {

    @Bean
    //@LoadBalanced  // 负载均衡注释
    public RestTemplate restTemplate(){
        return new RestTemplate();
    }
    public static void main(String[] args) {
        SpringApplication.run(ServiceConsumerApplication.class);
    }
}
